﻿<%@ Control Language="C#" Inherits="PlexBB.Controls.Admin.ForumManagement.AcpForumEdit" %>

<script type="text/javascript">
    // <![CDATA[
    // hide/show options based on forum type
    function displayOptions() {
        switch ($('#<%= sForumType.ClientID%>').val()) {
            case "Forum":
                $('#forum_link_options,#forum_cat_options').hide();
                $('#forum_post_options,#forum_rules_options').show();
                break;
            case "Link":
                $('#forum_post_options,#forum_rules_options,#forum_cat_options').hide();
                $('#forum_link_options').show();
                break;
            case "Category":
                $('#forum_post_options,#forum_link_options').hide();
                $('#forum_rules_options,#forum_cat_options').show();
                break;
        }
    }
    // call displayOptions on load
    $(displayOptions);
    // ]]>
</script>

<a name="maincontent"></a>
<asp:HyperLink runat="server" ID="hBack" CssClass="flowEnd" Text="<%$ Lang:BACK:&amp;laquo; {0} %>" />
<h1>
    <asp:Literal runat="server" ID="tTitle" />
    <asp:PlaceHolder runat="server" ID="cForumTitle">::
        <asp:Literal runat="server" ID="tForumTitle" Mode="Encode" />
    </asp:PlaceHolder>
</h1>
<p>
    <asp:Literal runat="server" Text="<%$ Lang:FORUM_EDIT_EXPLAIN%>" /></p>
<fieldset>
    <legend>
        <asp:Literal runat="server" Text="<%$ Lang:FORUM_SETTINGS%>" /></legend>
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="sForumType" Text="<%$ Lang:FORUM_TYPE:{0}:%>" /></dt>
        <dd>
            <asp:DropDownList runat="server" ID="sForumType" onchange="displayOptions();">
                <asp:ListItem Value="Category" Text="<%$ Lang:TYPE_CAT%>" />
                <asp:ListItem Value="Forum" Text="<%$ Lang:TYPE_FORUM%>" />
                <asp:ListItem Value="Link" Text="<%$ Lang:TYPE_LINK%>" />
            </asp:DropDownList>
        </dd>
    </dl>
    <!-- IF not S_ADD_ACTION and S_FORUM_ORIG_POST -->
    <div runat="server" id="cTypeActions">
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="kDeletePosts" Text="<%$ Lang:DECIDE_MOVE_DELETE_CONTENT:{0}:%>" /></dt>
            <dd>
                <asp:RadioButton runat="server" ID="kDeletePosts" Text="<%$ Lang:DELETE_ALL_POSTS %>"
                    GroupName="TypeAction" CssClass="radio" />
            </dd>
            <dd>
                <asp:RadioButton runat="server" ID="kMovePosts" Text="<%$ Lang:MOVE_POSTS_TO%>" GroupName="TypeAction"
                    CssClass="radio" />
                <asp:DropDownList runat="server" ID="sMovePostsTo" />
            </dd>
        </dl>
    </div>
    <!-- ENDIF -->
    <!-- IF not S_ADD_ACTION and S_FORUM_ORIG_CAT and S_HAS_SUBFORUMS -->
    <div runat="server" id="cCatToLinkActions">
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="kMoveSubforums" Text="<%$ Lang:DECIDE_MOVE_DELETE_SUBFORUMS:{0}:%>" /></dt>
            <dd>
                <asp:RadioButton runat="server" ID="kMoveSubforums" Text="<%$ Lang:MOVE_SUBFORUMS_TO %>"
                    GroupName="TypeAction" CssClass="radio" />
                <asp:DropDownList runat="server" ID="sMoveSubforumsTo" />
            </dd>
            <dd>
                <asp:RadioButton runat="server" ID="kDeleteSubforums" Text="<%$ Lang:DELETE_SUBFORUMS %>"
                    GroupName="TypeAction" CssClass="radio" /></dd>
        </dl>
    </div>
    <!-- ENDIF -->
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="sForumParentID" Text="<%$ Lang:FORUM_PARENT:{0}:%>" /></dt>
        <dd>
            <asp:DropDownList runat="server" ID="sForumParentID" />
        </dd>
    </dl>
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="tForumName" Text="<%$ Lang:FORUM_NAME:{0}:%>" /></dt>
        <dd>
            <asp:TextBox runat="server" ID="tForumName" CssClass="text medium" MaxLength="255" /></dd>
    </dl>
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="tForumDescription" Text="<%$ Lang:FORUM_DESC:{0}:%>" /><br />
            <asp:Label runat="server" Text="<%$ Lang:FORUM_DESC_EXPLAIN%>" /></dt>
        <dd>
            <asp:TextBox runat="server" ID="tForumDescription" Rows="5" Columns="45" TextMode="MultiLine" /></dd>
        <dd>
            <asp:CheckBox runat="server" ID="kDescriptionParseBBCode" CssClass="radio" Text="<%$ Lang:PARSE_BBCODE%>" />
            <asp:CheckBox runat="server" ID="kDescriptionParseSmilies" CssClass="radio" Text="<%$ Lang:PARSE_SMILIES%>" />
            <asp:CheckBox runat="server" ID="kDescriptionParseUrls" CssClass="radio" Text="<%$ Lang:PARSE_URLS%>" /></dd>
    </dl>
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="tForumImage" Text="<%$ Lang:FORUM_IMAGE:{0}:%>" /><br />
            <asp:Label runat="server" Text="<%$ Lang:FORUM_IMAGE_EXPLAIN%>" /></dt>
        <dd>
            <asp:TextBox runat="server" ID="tForumImage" CssClass="text medium" MaxLength="255" /></dd>
        <dd runat="server" id="cForumImage">
            <asp:Image runat="server" ID="iForumImage" AlternateText="<%$ Lang:FORUM_IMAGE%>" /></dd>
    </dl>
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="tForumPassword" Text="<%$ Lang:FORUM_PASSWORD:{0}:%>" /><br />
            <asp:Label runat="server" Text="<%$ Lang:FORUM_PASSWORD_EXPLAIN%>" /></dt>
        <dd>
            <asp:TextBox runat="server" ID="tForumPassword" TextMode="Password">ACB</asp:TextBox></dd>
    </dl>
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="tForumPasswordConfirm" Text="<%$ Lang:FORUM_PASSWORD_CONFIRM:{0}:%>" /><br />
            <asp:Label runat="server" Text="<%$ Lang:FORUM_PASSWORD_CONFIRM_EXPLAIN%>" /></dt>
        <dd>
            <asp:TextBox runat="server" ID="tForumPasswordConfirm" TextMode="Password" /></dd>
    </dl>
    <!-- IF S_FORUM_PASSWORD_SET -->
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="kForumPasswordUnset" Text="<%$ Lang:FORUM_PASSWORD_UNSET:{0}:%>" /><br />
            <asp:Label runat="server" Text="<%$ Lang:FORUM_PASSWORD_UNSET_EXPLAIN%>" /></dt>
        <dd>
            <asp:CheckBox runat="server" ID="kForumPasswordUnset" CssClass="radio" /></dd>
    </dl>
    <!-- ENDIF -->
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="sForumStyle" Text="<%$ Lang:FORUM_STYLE:{0}:%>" /></dt>
        <dd>
            <asp:DropDownList runat="server" ID="sForumStyle" />
        </dd>
    </dl>
    <!-- IF S_CAN_COPY_PERMISSIONS -->
    <dl>
        <dt>
            <asp:Label runat="server" AssociatedControlID="sCopyPersmissions" Text="<%$ Lang:COPY_PERMISSIONS:{0}:%>" /><br />
            <asp:Label ID="tCopyPermissionsExplain" runat="server" Text="<%$ Lang:COPY_PERMISSIONS_EXPLAIN%>" /></dt>
        <dd>
            <asp:DropDownList runat="server" ID="sCopyPersmissions" />
        </dd>
    </dl>
    <!-- ENDIF -->
</fieldset>
<div id="forum_cat_options">
    <fieldset>
        <legend>
            <asp:Literal runat="server" Text="<%$ Lang:GENERAL_FORUM_SETTINGS%>" /></legend>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sDisplayActiveTopics" Text="<%$ Lang:DISPLAY_ACTIVE_TOPICS:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:DISPLAY_ACTIVE_TOPICS_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sDisplayActiveTopics" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
    </fieldset>
</div>
<div id="forum_post_options">
    <fieldset>
        <legend>
            <asp:Literal runat="server" Text="<%$ Lang:GENERAL_FORUM_SETTINGS%>" /></legend>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sForumStatus" Text="<%$ Lang:FORUM_STATUS:{0}:%>" /></dt>
            <dd>
                <asp:DropDownList runat="server" ID="sForumStatus" />
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sDisplaySubforumsList" Text="<%$ Lang:LIST_SUBFORUMS:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:LIST_SUBFORUMS_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sDisplaySubforumsList" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sDisplayOnIndex" Text="<%$ Lang:LIST_INDEX:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:LIST_INDEX_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sDisplayOnIndex" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sEnablePostReview" Text="<%$ Lang:ENABLE_POST_REVIEW:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:ENABLE_POST_REVIEW_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sEnablePostReview" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sEnableIndexing" Text="<%$ Lang:ENABLE_INDEXING:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:ENABLE_INDEXING_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sEnableIndexing" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sEnableIcons" Text="<%$ Lang:ENABLE_TOPIC_ICONS:{0}:%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sEnableIcons" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sDisplayRecent" Text="<%$ Lang:ENABLE_RECENT:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:ENABLE_RECENT_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sDisplayRecent" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="tTopicsPerPage" Text="<%$ Lang:FORUM_TOPICS_PAGE:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:FORUM_TOPICS_PAGE_EXPLAIN%>" /></dt>
            <dd>
                <asp:TextBox runat="server" ID="tTopicsPerPage" MaxLength="4" Columns="4" /></dd>
        </dl>
    </fieldset>
    <fieldset>
        <legend>
            <asp:Literal runat="server" Text="<%$ Lang:FORUM_PRUNE_SETTINGS%>" /></legend>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sEnablePrune" Text="<%$ Lang:FORUM_AUTO_PRUNE:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:FORUM_AUTO_PRUNE_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sEnablePrune" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="tPruneFrequency" Text="<%$ Lang:AUTO_PRUNE_FREQ:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:AUTO_PRUNE_FREQ_EXPLAIN%>" /></dt>
            <dd>
                <asp:TextBox runat="server" ID="tPruneFrequency" MaxLength="4" Columns="4" />
                <asp:Literal runat="server" Text="<%$ Lang:DAYS%>" /></dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="tPruneDays" Text="<%$ Lang:AUTO_PRUNE_DAYS:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:AUTO_PRUNE_DAYS_EXPLAIN%>" /></dt>
            <dd>
                <asp:TextBox runat="server" ID="tPruneDays" MaxLength="4" Columns="4" />
                <asp:Literal runat="server" Text="<%$ Lang:DAYS%>" /></dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="tPruneViewed" Text="<%$ Lang:AUTO_PRUNE_VIEWED:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:AUTO_PRUNE_VIEWED_EXPLAIN%>" /></dt>
            <dd>
                <asp:TextBox runat="server" ID="tPruneViewed" MaxLength="4" Columns="4" />
                <asp:Literal runat="server" Text="<%$ Lang:DAYS%>" /></dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sPruneOldPolls" Text="<%$ Lang:PRUNE_OLD_POLLS:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:PRUNE_OLD_POLLS_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sPruneOldPolls" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sPruneAnnounce" Text="<%$ Lang:PRUNE_ANNOUNCEMENTS:{0}:%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sPruneAnnounce" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sPruneSticky" Text="<%$ Lang:PRUNE_STICKY:{0}:%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sPruneSticky" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
    </fieldset>
</div>
<div id="forum_link_options">
    <fieldset>
        <legend>
            <asp:Literal runat="server" Text="<%$ Lang:GENERAL_FORUM_SETTINGS%>" /></legend>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sLinkDisplayOnIndex" Text="<%$ Lang:LIST_INDEX:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:LIST_INDEX_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sLinkDisplayOnIndex" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="tForumLink" Text="<%$ Lang:FORUM_LINK:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:FORUM_LINK_EXPLAIN%>" /></dt>
            <dd>
                <asp:TextBox runat="server" ID="tForumLink" CssClass="text medium" MaxLength="255" /></dd>
        </dl>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sForumLinkTrack" Text="<%$ Lang:FORUM_LINK_TRACK:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:FORUM_LINK_TRACK_EXPLAIN%>" /></dt>
            <dd>
                <asp:RadioButtonList runat="server" ID="sForumLinkTrack" CssClass="radio" RepeatDirection="Horizontal"
                    RepeatLayout="Flow">
                    <asp:ListItem Value="true" Text="<%$ Lang:YES: {0}%>" />
                    <asp:ListItem Value="false" Text="<%$ Lang:NO: {0}%>" />
                </asp:RadioButtonList>
            </dd>
        </dl>
    </fieldset>
</div>
<div id="forum_rules_options">
    <fieldset>
        <legend>
            <asp:Literal runat="server" Text="<%$ Lang:FORUM_RULES%>" /></legend>
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="tForumRulesLink" Text="<%$ Lang:FORUM_RULES_LINK:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:FORUM_RULES_LINK_EXPLAIN%>" /></dt>
            <dd>
                <asp:TextBox runat="server" ID="tForumRulesLink" CssClass="text medium" MaxLength="255" /></dd>
        </dl>
        <!-- IF FORUM_RULES_PREVIEW -->
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="sPruneOldPolls" Text="<%$ Lang:FORUM_RULES_PREVIEW:{0}:%>" /></dt>
            <dd>
                {FORUM_RULES_PREVIEW}</dd>
        </dl>
        <!-- ENDIF -->
        <dl>
            <dt>
                <asp:Label runat="server" AssociatedControlID="tForumRules" Text="<%$ Lang:FORUM_RULES:{0}:%>" /><br />
                <asp:Label runat="server" Text="<%$ Lang:FORUM_RULES_EXPLAIN%>" /></dt>
            <dd>
                <asp:TextBox runat="server" ID="tForumRules" Rows="4" Columns="70" TextMode="MultiLine" /></dd>
            <dd>
                <asp:CheckBox runat="server" ID="kRulesParseBBCode" CssClass="radio" Text="<%$ Lang:PARSE_BBCODE%>" />
                <asp:CheckBox runat="server" ID="kRulesParseSmilies" CssClass="radio" Text="<%$ Lang:PARSE_SMILIES%>" />
                <asp:CheckBox runat="server" ID="kRulesParseUrl" CssClass="radio" Text="<%$ Lang:PARSE_URLS%>" /></dd>
        </dl>
    </fieldset>
</div>
<fieldset class="submit-buttons">
    <legend>
        <asp:Literal runat="server" Text="<%$ Lang:SUBMIT%>" /></legend>
    <asp:Button runat="server" ID="bForumSubmit" CssClass="button1" Text="<%$ Lang:SUBMIT%>"
        ValidationGroup="ForumEdit" />&nbsp;
    <input class="button2" type="reset" id="reset" runat="server" name="reset" value="<%$ Lang:RESET%>" />
</fieldset>
<%--	<script type="text/javascript">
	// <![CDATA[
		/**
		* Handle displaying/hiding several options based on the forum type
		*/
		function display_options(value)
		{
			<!-- IF not S_ADD_ACTION and S_FORUM_ORIG_POST -->
				if (value == {FORUM_POST})
				{
					dE('type_actions', -1);
				}
				else
				{
					dE('type_actions', 1);
				}
			<!-- ENDIF -->

			<!-- IF not S_ADD_ACTION and S_FORUM_ORIG_CAT and S_HAS_SUBFORUMS -->
				if (value == {FORUM_LINK})
				{
					dE('cat_to_link_actions', 1);
				}
				else
				{
					dE('cat_to_link_actions', -1);
				}
			<!-- ENDIF -->

			if (value == {FORUM_POST})
			{
				dE('forum_post_options', 1);
				dE('forum_link_options', -1);
				dE('forum_rules_options', 1);
				dE('forum_cat_options', -1);
			}
			else if (value == {FORUM_LINK})
			{
				dE('forum_post_options', -1);
				dE('forum_link_options', 1);
				dE('forum_rules_options', -1);
				dE('forum_cat_options', -1);
			}
			else if (value == {FORUM_CAT})
			{
				dE('forum_post_options', -1);
				dE('forum_link_options', -1);
				dE('forum_rules_options', 1);
				dE('forum_cat_options', 1);
			}
		}

		/**
		* Init the wanted display functionality if javascript is enabled.
		* If javascript is not available, the user is still able to properly administrate.
		*/
		onload = function()
		{
			<!-- IF not S_ADD_ACTION and S_FORUM_ORIG_POST -->
				<!-- IF S_FORUM_POST -->
					dE('type_actions', -1);
				<!-- ENDIF -->
			<!-- ENDIF -->

			<!-- IF not S_ADD_ACTION and S_FORUM_ORIG_CAT and S_HAS_SUBFORUMS -->
				<!-- IF S_FORUM_CAT -->
					dE('cat_to_link_actions', -1);
				<!-- ENDIF -->
			<!-- ENDIF -->

			<!-- IF not S_FORUM_POST -->
				dE('forum_post_options', -1);
			<!-- ENDIF -->

			<!-- IF not S_FORUM_CAT -->
				dE('forum_cat_options', -1);
			<!-- ENDIF -->

			<!-- IF not S_FORUM_LINK -->
				dE('forum_link_options', -1);
			<!-- ENDIF -->

			<!-- IF S_FORUM_LINK -->
			dE('forum_rules_options', -1);
			<!-- ENDIF -->
		}

	// ]]>
	</script>

	<a href="{U_BACK}" style="float: {S_CONTENT_FLOW_END};">&laquo; {L_BACK}</a>

	<h1>{L_TITLE} <!-- IF FORUM_NAME -->:: {FORUM_NAME}<!-- ENDIF --></h1>

	<p>{L_FORUM_EDIT_EXPLAIN}</p>

	<!-- IF S_ERROR -->
		<div class="errorbox">
			<h3>{L_WARNING}</h3>
			<p>{ERROR_MSG}</p>
		</div>
	<!-- ENDIF -->

	<form id="forumedit" method="post" action="{U_EDIT_ACTION}">

	<fieldset>
		<legend>{L_FORUM_SETTINGS}</legend>
	<dl>
		<dt><label for="forum_type">{L_FORUM_TYPE}:</label></dt>
		<dd><select id="forum_type" name="forum_type" onchange="display_options(this.options[this.selectedIndex].value);">{S_FORUM_TYPE_OPTIONS}</select></dd>
	</dl>
	<!-- IF not S_ADD_ACTION and S_FORUM_ORIG_POST -->
	<div id="type_actions">
		<dl>
			<dt><label for="type_action">{L_DECIDE_MOVE_DELETE_CONTENT}:</label></dt>
			<dd><label><input type="radio" class="radio" name="type_action" value="delete"<!-- IF not S_MOVE_FORUM_OPTIONS --> checked="checked" id="type_action"<!-- ENDIF --> /> {L_DELETE_ALL_POSTS}</label></dd>
			<!-- IF S_MOVE_FORUM_OPTIONS --><dd><label><input type="radio" class="radio" name="type_action" id="type_action" value="move" checked="checked" /> {L_MOVE_POSTS_TO}</label> <select name="to_forum_id">{S_MOVE_FORUM_OPTIONS}</select></dd><!-- ENDIF -->
		</dl>
	</div>
	<!-- ENDIF -->
	<!-- IF not S_ADD_ACTION and S_FORUM_ORIG_CAT and S_HAS_SUBFORUMS -->
	<div id="cat_to_link_actions">
		<dl>
			<dt><label for="action_subforums">{L_DECIDE_MOVE_DELETE_SUBFORUMS}:</label></dt>
			<!-- IF S_FORUMS_LIST -->
				<dd><label><input type="radio" class="radio" id="action_subforums" name="action_subforums" value="move" checked="checked" /> {L_MOVE_SUBFORUMS_TO}</label> <select name="subforums_to_id">{S_FORUMS_LIST}</select></dd>
			<!-- ELSE -->
				<dd><label><input type="radio" class="radio" id="action_subforums" name="action_subforums" value="delete" checked="checked" /> {L_DELETE_SUBFORUMS}</label></dd>
			<!-- ENDIF -->
		</dl>
	</div>
	<!-- ENDIF -->
	<dl>
		<dt><label for="parent">{L_FORUM_PARENT}:</label></dt>
		<dd><select id="parent" name="forum_parent_id"><option value="0"<!-- IF not S_FORUM_PARENT_ID --> selected="selected"<!-- ENDIF -->>{L_NO_PARENT}</option>{S_PARENT_OPTIONS}</select></dd>
	</dl>
	<dl>
		<dt><label for="forum_name">{L_FORUM_NAME}:</label></dt>
		<dd><input class="text medium" type="text" id="forum_name" name="forum_name" value="{FORUM_NAME}" maxlength="255" /></dd>
	</dl>
	<dl>
		<dt><label for="forum_desc">{L_FORUM_DESC}:</label><br /><span>{L_FORUM_DESC_EXPLAIN}</span></dt>
		<dd><textarea id="forum_desc" name="forum_desc" rows="5" cols="45">{FORUM_DESC}</textarea></dd>
		<dd><label><input type="checkbox" class="radio" name="desc_parse_bbcode"<!-- IF S_DESC_BBCODE_CHECKED --> checked="checked"<!-- ENDIF --> /> {L_PARSE_BBCODE}</label>
			<label><input type="checkbox" class="radio" name="desc_parse_smilies"<!-- IF S_DESC_SMILIES_CHECKED --> checked="checked"<!-- ENDIF --> /> {L_PARSE_SMILIES}</label>
			<label><input type="checkbox" class="radio" name="desc_parse_urls"<!-- IF S_DESC_URLS_CHECKED --> checked="checked"<!-- ENDIF --> /> {L_PARSE_URLS}</label></dd>
	</dl>
	<dl>
		<dt><label for="forum_image">{L_FORUM_IMAGE}:</label><br /><span>{L_FORUM_IMAGE_EXPLAIN}</span></dt>
		<dd><input class="text medium" type="text" id="forum_image" name="forum_image" value="{FORUM_IMAGE}" maxlength="255" /></dd>
		<!-- IF FORUM_IMAGE_SRC -->
			<dd><img src="{FORUM_IMAGE_SRC}" alt="{L_FORUM_IMAGE}" /></dd>
		<!-- ENDIF -->
	</dl>
	<dl>
		<dt><label for="forum_password">{L_FORUM_PASSWORD}:</label><br /><span>{L_FORUM_PASSWORD_EXPLAIN}</span></dt>
		<dd><input type="password" id="forum_password" name="forum_password" value="<!-- IF S_FORUM_PASSWORD_SET -->&#x20;&#x20;&#x20;&#x20;&#x20;&#x20;<!-- ENDIF -->" /></dd>
	</dl>
	<dl>
		<dt><label for="forum_password_confirm">{L_FORUM_PASSWORD_CONFIRM}:</label><br /><span>{L_FORUM_PASSWORD_CONFIRM_EXPLAIN}</span></dt>
		<dd><input type="password" id="forum_password_confirm" name="forum_password_confirm" value="<!-- IF S_FORUM_PASSWORD_SET -->&#x20;&#x20;&#x20;&#x20;&#x20;&#x20;<!-- ENDIF -->" /></dd>
	</dl>
	<!-- IF S_FORUM_PASSWORD_SET -->
	<dl>
		<dt><label for="forum_password_unset">{L_FORUM_PASSWORD_UNSET}:</label><br /><span>{L_FORUM_PASSWORD_UNSET_EXPLAIN}</span></dt>
		<dd><input id="forum_password_unset" name="forum_password_unset" type="checkbox" /></dd>
	</dl>
	<!-- ENDIF -->
	<dl>
		<dt><label for="forum_style">{L_FORUM_STYLE}:</label></dt>
		<dd><select id="forum_style" name="forum_style"><option value="0">{L_DEFAULT_STYLE}</option>{S_STYLES_OPTIONS}</select></dd>
	</dl>
	<!-- IF S_CAN_COPY_PERMISSIONS -->
		<dl>
			<dt><label for="forum_perm_from">{L_COPY_PERMISSIONS}:</label><br /><span>{L_COPY_PERMISSIONS_EXPLAIN}</span></dt>
			<dd><select id="forum_perm_from" name="forum_perm_from"><option value="0">{L_NO_PERMISSIONS}</option>{S_FORUM_OPTIONS}</select></dd>
		</dl>
	<!-- ENDIF -->
	</fieldset>

	<div id="forum_cat_options">
		<fieldset>
			<legend>{L_GENERAL_FORUM_SETTINGS}</legend>
		<dl>
			<dt><label for="display_active">{L_DISPLAY_ACTIVE_TOPICS}:</label><br /><span>{L_DISPLAY_ACTIVE_TOPICS_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="display_active" value="1"<!-- IF S_DISPLAY_ACTIVE_TOPICS --> id="display_active" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="display_active" value="0"<!-- IF not S_DISPLAY_ACTIVE_TOPICS --> id="display_active" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		</fieldset>
	</div>

	<div id="forum_post_options">
		<fieldset>
			<legend>{L_GENERAL_FORUM_SETTINGS}</legend>
		<dl>
			<dt><label for="forum_status">{L_FORUM_STATUS}:</label></dt>
			<dd><select id="forum_status" name="forum_status">{S_STATUS_OPTIONS}</select></dd>
		</dl>
		<dl>
			<dt><label for="display_subforum_list">{L_LIST_SUBFORUMS}:</label><br /><span>{L_LIST_SUBFORUMS_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="display_subforum_list" value="1"<!-- IF S_DISPLAY_SUBFORUM_LIST --> id="display_subforum_list" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="display_subforum_list" value="0"<!-- IF not S_DISPLAY_SUBFORUM_LIST --> id="display_subforum_list" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="display_on_index">{L_LIST_INDEX}:</label><br /><span>{L_LIST_INDEX_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="display_on_index" value="1"<!-- IF S_DISPLAY_ON_INDEX --> id="display_on_index" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="display_on_index" value="0"<!-- IF not S_DISPLAY_ON_INDEX --> id="display_on_index" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="enable_post_review">{L_ENABLE_POST_REVIEW}:</label><br /><span>{L_ENABLE_POST_REVIEW_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="enable_post_review" value="1"<!-- IF S_ENABLE_POST_REVIEW --> id="enable_post_review" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="enable_post_review" value="0"<!-- IF not S_ENABLE_POST_REVIEW --> id="enable_post_review" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="enable_indexing">{L_ENABLE_INDEXING}:</label><br /><span>{L_ENABLE_INDEXING_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="enable_indexing" value="1"<!-- IF S_ENABLE_INDEXING --> id="enable_indexing" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="enable_indexing" value="0"<!-- IF not S_ENABLE_INDEXING --> id="enable_indexing" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="enable_icons">{L_ENABLE_TOPIC_ICONS}:</label></dt>
			<dd><label><input type="radio" class="radio" name="enable_icons" value="1"<!-- IF S_TOPIC_ICONS --> id="enable_icons" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="enable_icons" value="0"<!-- IF not S_TOPIC_ICONS --> id="enable_icons" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="display_recent">{L_ENABLE_RECENT}:</label><br /><span>{L_ENABLE_RECENT_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="display_recent" value="1"<!-- IF S_DISPLAY_ACTIVE_TOPICS --> id="display_recent" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="display_recent" value="0"<!-- IF not S_DISPLAY_ACTIVE_TOPICS --> id="display_recent" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="topics_per_page">{L_FORUM_TOPICS_PAGE}:</label><br /><span>{L_FORUM_TOPICS_PAGE_EXPLAIN}</span></dt>
			<dd><input type="text" id="topics_per_page" name="topics_per_page" value="{TOPICS_PER_PAGE}" size="4" maxlength="4" /></dd>
		</dl>
		</fieldset>

		<fieldset>
			<legend>{L_FORUM_PRUNE_SETTINGS}</legend>
		<dl>
			<dt><label for="enable_prune">{L_FORUM_AUTO_PRUNE}:</label><br /><span>{L_FORUM_AUTO_PRUNE_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="enable_prune" value="1"<!-- IF S_PRUNE_ENABLE --> id="enable_prune" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="enable_prune" value="0"<!-- IF not S_PRUNE_ENABLE --> id="enable_prune" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="prune_freq">{L_AUTO_PRUNE_FREQ}:</label><br /><span>{L_AUTO_PRUNE_FREQ_EXPLAIN}</span></dt>
			<dd><input type="text" id="prune_freq" name="prune_freq" value="{PRUNE_FREQ}" maxlength="4" size="4" /> {L_DAYS}</dd>
		</dl>
		<dl>
			<dt><label for="prune_days">{L_AUTO_PRUNE_DAYS}:</label><br /><span>{L_AUTO_PRUNE_DAYS_EXPLAIN}</span></dt>
			<dd><input type="text" id="prune_days" name="prune_days" value="{PRUNE_DAYS}" maxlength="4" size="4" /> {L_DAYS}</dd>
		</dl>
		<dl>
			<dt><label for="prune_viewed">{L_AUTO_PRUNE_VIEWED}:</label><br /><span>{L_AUTO_PRUNE_VIEWED_EXPLAIN}</span></dt>
			<dd><input type="text" id="prune_viewed" name="prune_viewed" value="{PRUNE_VIEWED}" maxlength="4" size="4" /> {L_DAYS}</dd>
		</dl>
		<dl>
			<dt><label for="prune_old_polls">{L_PRUNE_OLD_POLLS}:</label><br /><span>{L_PRUNE_OLD_POLLS_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="prune_old_polls" value="1"<!-- IF S_PRUNE_OLD_POLLS --> id="prune_old_polls" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="prune_old_polls" value="0"<!-- IF not S_PRUNE_OLD_POLLS --> id="prune_old_polls" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="prune_announce">{L_PRUNE_ANNOUNCEMENTS}:</label></dt>
			<dd><label><input type="radio" class="radio" name="prune_announce" value="1"<!-- IF S_PRUNE_ANNOUNCE --> id="prune_announce" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="prune_announce" value="0"<!-- IF not S_PRUNE_ANNOUNCE --> id="prune_announce" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="prune_sticky">{L_PRUNE_STICKY}:</label></dt>
			<dd><label><input type="radio" class="radio" name="prune_sticky" value="1"<!-- IF S_PRUNE_STICKY --> id="prune_sticky" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="prune_sticky" value="0"<!-- IF not S_PRUNE_STICKY --> id="prune_sticky" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		</fieldset>
	</div>

	<div id="forum_link_options">
		<fieldset>
			<legend>{L_GENERAL_FORUM_SETTINGS}</legend>
		<dl>
			<dt><label for="link_display_on_index">{L_LIST_INDEX}:</label><br /><span>{L_LIST_INDEX_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="link_display_on_index" value="1"<!-- IF S_DISPLAY_ON_INDEX --> id="link_display_on_index" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="link_display_on_index" value="0"<!-- IF not S_DISPLAY_ON_INDEX --> id="link_display_on_index" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		<dl>
			<dt><label for="forum_link">{L_FORUM_LINK}:</label><br /><span>{L_FORUM_LINK_EXPLAIN}</span></dt>
			<dd><input class="text medium" type="text" id="forum_link" name="forum_link" value="{FORUM_DATA_LINK}" maxlength="255" /></dd>
		</dl>
		<dl>
			<dt><label for="forum_link_track">{L_FORUM_LINK_TRACK}:</label><br /><span>{L_FORUM_LINK_TRACK_EXPLAIN}</span></dt>
			<dd><label><input type="radio" class="radio" name="forum_link_track" value="1"<!-- IF S_FORUM_LINK_TRACK --> id="forum_link_track" checked="checked"<!-- ENDIF --> /> {L_YES}</label>
				<label><input type="radio" class="radio" name="forum_link_track" value="0"<!-- IF not S_FORUM_LINK_TRACK --> id="forum_link_track" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd>
		</dl>
		</fieldset>
	</div>

	<div id="forum_rules_options">
		<fieldset>
			<legend>{L_FORUM_RULES}</legend>
		<dl>
			<dt><label for="forum_rules_link">{L_FORUM_RULES_LINK}:</label><br /><span>{L_FORUM_RULES_LINK_EXPLAIN}</span></dt>
			<dd><input class="text medium" type="text" id="forum_rules_link" name="forum_rules_link" value="{FORUM_RULES_LINK}" maxlength="255" /></dd>
		</dl>
	<!-- IF FORUM_RULES_PREVIEW -->
		<dl>
			<dt><label>{L_FORUM_RULES_PREVIEW}:</label></dt>
			<dd>{FORUM_RULES_PREVIEW}</dd>
		</dl>
	<!-- ENDIF -->
		<dl>
			<dt><label for="forum_rules">{L_FORUM_RULES}:</label><br /><span>{L_FORUM_RULES_EXPLAIN}</span></dt>
			<dd><textarea id="forum_rules" name="forum_rules" rows="4" cols="70">{FORUM_RULES_PLAIN}</textarea></dd>
			<dd><label><input type="checkbox" class="radio" name="rules_parse_bbcode"<!-- IF S_BBCODE_CHECKED --> checked="checked"<!-- ENDIF --> /> {L_PARSE_BBCODE}</label>
				<label><input type="checkbox" class="radio" name="rules_parse_smilies"<!-- IF S_SMILIES_CHECKED --> checked="checked"<!-- ENDIF --> /> {L_PARSE_SMILIES}</label>
				<label><input type="checkbox" class="radio" name="rules_parse_urls"<!-- IF S_URLS_CHECKED --> checked="checked"<!-- ENDIF --> /> {L_PARSE_URLS}</label></dd>
		</dl>
		</fieldset>
	</div>

	<fieldset class="submit-buttons">
		<legend>{L_SUBMIT}</legend>
		<input class="button1" type="submit" id="submit" name="update" value="{L_SUBMIT}" />&nbsp;
		<input class="button2" type="reset" id="reset" name="reset" value="{L_RESET}" />
		{S_FORM_TOKEN}
	</fieldset>
	</form>
--%>